<%@ page language="java" import="java.util.*,service.*,model.*" pageEncoding="UTF-8"%>
<%

	String viewerid = (String)request.getAttribute("viewerid");
	String ownerid = (String)request.getAttribute("ownerid");
	
	boolean self = viewerid.equals(ownerid);
	SaleData sdata = FriendSale.getDataObj(ownerid);
	
	List<String> slaveids = sdata.getSlaves();
	for(String slaveid:slaveids){
		SaleData slavedata = FriendSale.getDataObj(slaveid);
		Person slave = slavedata.getPerson();
%>
			 <div class="nl_list">
				  <div class="dealimg2 l">
				    <a href="http://www.kaixin001.com/%7Eslave/index.php?uid=2260522" class="sl2"><img src="<%=slave.getThumbnail() %>" width="50" height="50"></a>
				  </div>
				<div class="l" style="margin-left: 10px;width:300px;">
					<div class="l">
						<div>
							<div class="l"><strong><a href="http://www.kaixin001.com/%7Eslave/index.php?uid=2260522" class="sl2"><%=slave.getName() %></a></strong>(<%=slavedata.getNickname() %>)</div>
						</div>
						<div class="c"></div>
						
						身　价：<strong class="dgreen">¥<%=slavedata.getPrice() %></strong><br>
						<!-- 总资产：<strong class="dgreen">¥10002</strong><br>-->
						现　金：<strong class="dgreen">¥<%=slavedata.getCash() %></strong><br>
						奴隶数：<strong class="dred"><%=slavedata.getSlaves().size() %></strong><br>
						
					</div>
					<div class="r wysft">
						<ul class="action_list" id="slave_actions">
						<% if(self){ %>
						<li><a href="javascript:stuffdialog('<%=slavedata.getId() %>','1')">我要释放她</a></li>
						<li><a href="javascript:stuffdialog('<%=slavedata.getId() %>','3')">打折处理</a></li>
						<li><a href="javascript:stuffdialog('<%=slavedata.getId() %>','bad')">蹂躏她</a></li>
						<li><a href="javascript:stuffdialog('<%=slavedata.getId() %>','good')">安抚她</a></li>
						<%}%>
						</ul>
				</div>
					<div class="c"></div>
					<!-- <div class="djl">
						<div class="l">
							从 <a href="http://www.kaixin001.com/%7Eslave/index.php?uid=2082908" class="sl2">张云波</a> 手中花<span class="dgreen"><strong>¥</strong>14020</span> 购买
						</div>
						<div class="gw13">2008-10-24 15:48</div>
					</div> -->
				</div>
				
				<div class="c"></div>
			 </div>
			 
<%
}
%>